Skip to content

Commit

Permalink
remove unnecessary files
Browse files Browse the repository at this point in the history
  • Loading branch information
dnbrwstr committed Jan 14, 2025
1 parent 6e001d7 commit de91035
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 25 deletions.
16 changes: 15 additions & 1 deletion packages/ui/src/components/Form/Field.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,24 @@
import React, { useContext } from 'react';
import { YStack, styled } from 'tamagui';
import { createStyledContext } from 'tamagui';

import { VariantsFromStyledContext } from '../../types';
import { Text } from '../TextV2';
import { FieldContext } from './FieldContext';
import { FormContext } from './Form';
import { Accent, BackgroundType } from './formUtils';

// Single field
type FieldContextValue = {
accent: Accent;
disabled: boolean;
backgroundType: BackgroundType;
};

export const FieldContext = createStyledContext<FieldContextValue>({
accent: 'neutral',
disabled: false,
backgroundType: 'primary',
});

export const FieldFrame = styled(YStack, {
context: FieldContext,
Expand Down
16 changes: 0 additions & 16 deletions packages/ui/src/components/Form/FieldContext.tsx

This file was deleted.

7 changes: 0 additions & 7 deletions packages/ui/src/components/Form/FormContext.tsx

This file was deleted.

2 changes: 1 addition & 1 deletion packages/ui/src/components/Form/inputs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ import { useBoundHandler } from '../ListItem/listItemUtils';
import Pressable from '../Pressable';
import { Text } from '../TextV2';
import { typeStyles } from '../TextV2/Text';
import { FieldContext } from './FieldContext';
import { FieldContext } from './Field';
import {
Accent,
getBorderVariantStyle as getBackgroundTypeVariantStyle,
Expand Down

0 comments on commit de91035

Please sign in to comment.