Skip to content

Commit

Permalink
Merge pull request #14 from bleu-fi/luiza/cow-187-link-ponder-and-cow…
Browse files Browse the repository at this point in the history
…-api

Link ponder and cow API
  • Loading branch information
luizakp authored Mar 11, 2024
2 parents 3535b2a + 079a76d commit 495a225
Show file tree
Hide file tree
Showing 55 changed files with 136 additions and 57 deletions.
2 changes: 1 addition & 1 deletion src/app/history/(components)/OrderTable/TableRowOrder.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { TrashIcon } from "@radix-ui/react-icons";
import Table from "#/components/Table";
import { TokenInfo } from "#/components/TokenInfo";
import { StopLossOrderType } from "#/hooks/useOrders";
import { formatDateToLocalDatetime } from "#/lib/utils";
import { formatDateToLocalDatetime } from "#/utils";

export function TableRowOrder({ order }: { order: StopLossOrderType }) {
const orderStatus = "Created";
Expand Down
2 changes: 1 addition & 1 deletion src/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { Inter as FontSans } from "next/font/google";

import { Footer } from "#/components/Footer";
import { RootLayout } from "#/components/RootLayout";
import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const fontSans = FontSans({
subsets: ["latin"],
Expand Down
2 changes: 1 addition & 1 deletion src/components/AlertCard.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import cn from "clsx";

import { capitalize } from "#/lib/utils";
import { capitalize } from "#/utils";

export function AlertCard({
title,
Expand Down
2 changes: 1 addition & 1 deletion src/components/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import Image from "next/image";
import Link from "next/link";
import { ReactNode } from "react";

import { NetworkChainId, truncateAddress } from "#/lib/utils";
import { NetworkChainId, truncateAddress } from "#/utils";

interface IHeader {
linkUrl: string;
Expand Down
2 changes: 1 addition & 1 deletion src/components/TokenInfo.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import Image from "next/image";

import { cowTokenList } from "#/lib/cowTokenList";
import { formatNumber, truncateAddress } from "#/lib/utils";
import { formatNumber, truncateAddress } from "#/utils";

export function TokenInfo({
symbol,
Expand Down
2 changes: 1 addition & 1 deletion src/components/menus/SwapMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { useSafeBalances } from "#/hooks/useSafeBalances";
import { ChainId } from "#/lib/publicClients";
import { generateSwapSchema } from "#/lib/schema";
import { ISwapData, TIME_OPTIONS } from "#/lib/types";
import { convertAndRoundDown, formatNumber } from "#/lib/utils";
import { convertAndRoundDown, formatNumber } from "#/utils";

import Button from "../Button";
import { Checkbox } from "../Checkbox";
Expand Down
2 changes: 1 addition & 1 deletion src/components/nodes/index.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from "react";
import { Handle, Position } from "reactflow";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

export interface IBaseNode {
children: React.ReactNode;
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/accordion.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import * as AccordionPrimitive from "@radix-ui/react-accordion";
import { ChevronDownIcon } from "@radix-ui/react-icons";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Accordion = AccordionPrimitive.Root;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/alert-dialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog";
import * as React from "react";

import { buttonVariants } from "#/components/ui/button";
import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const AlertDialog = AlertDialogPrimitive.Root;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/alert.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { cva, type VariantProps } from "class-variance-authority";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const alertVariants = cva(
"relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7",
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/avatar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import * as AvatarPrimitive from "@radix-ui/react-avatar";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Avatar = React.forwardRef<
React.ElementRef<typeof AvatarPrimitive.Root>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/badge.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { cva, type VariantProps } from "class-variance-authority";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const badgeVariants = cva(
"inline-flex items-center rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { Slot } from "@radix-ui/react-slot";
import { cva, type VariantProps } from "class-variance-authority";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const buttonVariants = cva(
"inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50",
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/calendar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import * as React from "react";
import { DayPicker } from "react-day-picker";

import { buttonVariants } from "#/components/ui/button";
import { cn } from "#/lib/utils";
import { cn } from "#/utils";

export type CalendarProps = React.ComponentProps<typeof DayPicker>;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/card.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Card = React.forwardRef<
HTMLDivElement,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/carousel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import useEmblaCarousel, {
import * as React from "react";

import { Button } from "#/components/ui/button";
import { cn } from "#/lib/utils";
import { cn } from "#/utils";

type CarouselApi = UseEmblaCarouselType[1];
type UseCarouselParameters = Parameters<typeof useEmblaCarousel>;
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/checkbox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
import { CheckIcon } from "@radix-ui/react-icons";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Checkbox = React.forwardRef<
React.ElementRef<typeof CheckboxPrimitive.Root>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/command.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { Command as CommandPrimitive } from "cmdk";
import * as React from "react";

import { Dialog, DialogContent } from "#/components/ui/dialog";
import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Command = React.forwardRef<
React.ElementRef<typeof CommandPrimitive>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/context-menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
} from "@radix-ui/react-icons";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const ContextMenu = ContextMenuPrimitive.Root;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/dialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import * as DialogPrimitive from "@radix-ui/react-dialog";
import { Cross2Icon } from "@radix-ui/react-icons";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Dialog = DialogPrimitive.Root;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/drawer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import * as React from "react";
import { Drawer as DrawerPrimitive } from "vaul";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Drawer = ({
shouldScaleBackground = true,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/dropdown-menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
} from "@radix-ui/react-icons";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const DropdownMenu = DropdownMenuPrimitive.Root;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/form.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import {
UseFormReturn,
} from "react-hook-form";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

import { Label } from "./label";

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/hover-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import * as HoverCardPrimitive from "@radix-ui/react-hover-card";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const HoverCard = HoverCardPrimitive.Root;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/input.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

export interface InputProps
extends React.InputHTMLAttributes<HTMLInputElement> {}
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/label.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import * as LabelPrimitive from "@radix-ui/react-label";
import { cva, type VariantProps } from "class-variance-authority";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const labelVariants = cva(
"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70",
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/menubar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
import * as MenubarPrimitive from "@radix-ui/react-menubar";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const MenubarMenu = MenubarPrimitive.Menu;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/navigation-menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu";
import { cva } from "class-variance-authority";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const NavigationMenu = React.forwardRef<
React.ElementRef<typeof NavigationMenuPrimitive.Root>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/pagination.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {
import * as React from "react";

import { ButtonProps, buttonVariants } from "#/components/ui/button";
import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Pagination = ({ className, ...props }: React.ComponentProps<"nav">) => (
<nav
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/popover.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import * as PopoverPrimitive from "@radix-ui/react-popover";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Popover = PopoverPrimitive.Root;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/progress.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import * as ProgressPrimitive from "@radix-ui/react-progress";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Progress = React.forwardRef<
React.ElementRef<typeof ProgressPrimitive.Root>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/radio-group.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { CheckIcon } from "@radix-ui/react-icons";
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const RadioGroup = React.forwardRef<
React.ElementRef<typeof RadioGroupPrimitive.Root>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/resizable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import { DragHandleDots2Icon } from "@radix-ui/react-icons";
import * as ResizablePrimitive from "react-resizable-panels";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const ResizablePanelGroup = ({
className,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/scroll-area.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const ScrollArea = React.forwardRef<
React.ElementRef<typeof ScrollAreaPrimitive.Root>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/select.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
import * as SelectPrimitive from "@radix-ui/react-select";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Select = SelectPrimitive.Root;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/separator.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import * as SeparatorPrimitive from "@radix-ui/react-separator";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Separator = React.forwardRef<
React.ElementRef<typeof SeparatorPrimitive.Root>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/sheet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { Cross2Icon } from "@radix-ui/react-icons";
import { cva, type VariantProps } from "class-variance-authority";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Sheet = SheetPrimitive.Root;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/skeleton.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { cn } from "#/lib/utils";
import { cn } from "#/utils";

function Skeleton({
className,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/slider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import * as SliderPrimitive from "@radix-ui/react-slider";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Slider = React.forwardRef<
React.ElementRef<typeof SliderPrimitive.Root>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/switch.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import * as SwitchPrimitives from "@radix-ui/react-switch";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Switch = React.forwardRef<
React.ElementRef<typeof SwitchPrimitives.Root>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/table.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Table = React.forwardRef<
HTMLTableElement,
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/tabs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import * as TabsPrimitive from "@radix-ui/react-tabs";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const Tabs = TabsPrimitive.Root;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/textarea.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

export interface TextareaProps
extends React.TextareaHTMLAttributes<HTMLTextAreaElement> {}
Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/toast.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import * as ToastPrimitives from "@radix-ui/react-toast";
import { cva, type VariantProps } from "class-variance-authority";
import * as React from "react";

import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const ToastProvider = ToastPrimitives.Provider;

Expand Down
2 changes: 1 addition & 1 deletion src/components/ui/toggle-group.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { VariantProps } from "class-variance-authority";
import * as React from "react";

import { toggleVariants } from "#/components/ui/toggle";
import { cn } from "#/lib/utils";
import { cn } from "#/utils";

const ToggleGroupContext = React.createContext<
VariantProps<typeof toggleVariants>
Expand Down
Loading

0 comments on commit 495a225

Please sign in to comment.