Skip to content

Commit

Permalink
feat: final
Browse files Browse the repository at this point in the history
  • Loading branch information
danielsimao committed Sep 15, 2023
1 parent e3caca2 commit ea64a94
Show file tree
Hide file tree
Showing 160 changed files with 548 additions and 1,159 deletions.
2 changes: 1 addition & 1 deletion .eslintcache

Large diffs are not rendered by default.

16 changes: 8 additions & 8 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: Release

on:
push:
paths:
- ".changeset/**"
- "packages/**"
# paths:
# - '.changeset/**'
# - 'packages/**'
branches:
- master

Expand All @@ -30,12 +30,12 @@ jobs:
uses: changesets/action@v1
with:
publish: pnpm release
title: "ci(changesets): :package: version packages"
commit: "ci(changesets): version packages"
title: 'ci(changesets): :package: version packages'
commit: 'ci(changesets): version packages'
setupGitUser: false
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
NPM_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Create @dev release
Expand All @@ -45,5 +45,5 @@ jobs:
pnpm version:dev
pnpm release:dev
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
17 changes: 1 addition & 16 deletions .storybook/main.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import type { StorybookConfig } from '@storybook/react-vite';
import { mergeConfig } from 'vite';
import { join, dirname, resolve } from 'path';
import { join, dirname } from 'path';

/**
* This function is used to resolve the absolute path of a package.
Expand Down Expand Up @@ -29,20 +28,6 @@ const config: StorybookConfig = {
},
core: {
disableTelemetry: true
},

async viteFinal(config) {
// Merge custom configuration into the default config
return mergeConfig(config, {
resolve: {
alias: [
{
find: /\@just_testing13\/icon$/,
replacement: resolve(__dirname, '../packages/icons/icon/src')
}
]
}
});
}
};

Expand Down
5 changes: 1 addition & 4 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ module.exports = {
testEnvironment: 'jsdom',
collectCoverageFrom: ['packages/**/*.{ts,tsx}'],
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
moduleNameMapper: {
"@just_testing13/icon$": "<rootDir>/packages/icons/core/src",
},
transform: {
'^.+\\.(t|j)sx?$': [
'@swc/jest',
Expand All @@ -21,7 +18,7 @@ module.exports = {
]
},
transformIgnorePatterns: ['[/\\\\]node_modules[/\\\\].+\\.(js|jsx)$'],
setupFilesAfterEnv: ["@testing-library/jest-dom/extend-expect", './scripts/setup-test.ts'],
setupFilesAfterEnv: ['@testing-library/jest-dom/extend-expect', './scripts/setup-test.ts'],
testTimeout: 10000,
globals: {
'ts-jest': {
Expand Down
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,7 @@
"storybook": "^7.4.0",
"tsup": "^7.2.0",
"turbo": "latest",
"typescript": ">=3.0.0",
"vite": "^4.4.9"
"typescript": ">=3.0.0"
},
"pnpm": {
"overrides": {
Expand Down
101 changes: 0 additions & 101 deletions packages/components/CHANGELOG.md

This file was deleted.

17 changes: 8 additions & 9 deletions packages/components/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@just_testing13/ui",
"version": "0.2.0",
"name": "@interlay/ui",
"version": "0.0.0",
"description": "Interlay UI library.",
"homepage": "https://github.com/interlay/ui#readme",
"license": "MIT",
Expand Down Expand Up @@ -38,11 +38,11 @@
"postpack": "clean-package restore"
},
"dependencies": {
"@just_testing13/hooks": "workspace:*",
"@just_testing13/icons": "workspace:*",
"@just_testing13/coin-icons": "workspace:*",
"@just_testing13/theme": "workspace:*",
"@just_testing13/system": "workspace:*",
"@interlay/hooks": "workspace:*",
"@interlay/icons": "workspace:*",
"@interlay/coin-icons": "workspace:*",
"@interlay/theme": "workspace:*",
"@interlay/system": "workspace:*",
"@react-aria/accordion": "3.0.0-alpha.20",
"@react-aria/breadcrumbs": "^3.5.4",
"@react-aria/button": "^3.8.1",
Expand Down Expand Up @@ -92,8 +92,7 @@
"clean-package": "^2.2.0",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"@just_testing13/test-utils": "workspace:*",
"@just_testing13/icon": "workspace:*",
"@interlay/test-utils": "workspace:*",
"styled-components": "^6.0.7"
},
"clean-package": "../../clean-package.config.json"
Expand Down
4 changes: 2 additions & 2 deletions packages/components/src/Accordion/Accordion.style.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import styled from 'styled-components';
import { ChevronDown } from '@just_testing13/icons';
import { theme } from '@just_testing13/theme';
import { ChevronDown } from '@interlay/icons';
import { theme } from '@interlay/theme';

import { H3 } from '../Text';

Expand Down
4 changes: 2 additions & 2 deletions packages/components/src/Accordion/Accordion.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import { AriaAccordionProps, useAccordion } from '@react-aria/accordion';
import { mergeProps } from '@react-aria/utils';
import { useTreeState } from '@react-stately/tree';
import { forwardRef, HTMLAttributes, Ref } from 'react';
import { FontSize } from '@just_testing13/theme';
import { useDOMRef } from '@just_testing13/hooks';
import { FontSize } from '@interlay/theme';
import { useDOMRef } from '@interlay/hooks';

import { AccordionItem } from './AccordionItem';

Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/Accordion/AccordionItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { mergeProps } from '@react-aria/utils';
import { TreeState } from '@react-stately/tree';
import { Node } from '@react-types/shared';
import { useRef } from 'react';
import { FontSize } from '@just_testing13/theme';
import { FontSize } from '@interlay/theme';

import {
StyledAccordionItemButton,
Expand Down
6 changes: 3 additions & 3 deletions packages/components/src/Alert/Alert.style.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Warning } from '@just_testing13/icons';
import { Warning } from '@interlay/icons';
import styled from 'styled-components';
import { theme } from '@just_testing13/theme';
import { Status } from '@just_testing13/theme';
import { theme } from '@interlay/theme';
import { Status } from '@interlay/theme';

import { Flex } from '../Flex';

Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/Alert/Alert.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Status } from '@just_testing13/theme';
import { Status } from '@interlay/theme';

import { FlexProps } from '../Flex';

Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/Breadcrumbs/BreadcrumbItem.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { AriaBreadcrumbItemProps, useBreadcrumbItem } from '@react-aria/breadcrumbs';
import { mergeProps } from '@react-aria/utils';
import { AnchorHTMLAttributes, Fragment, useRef } from 'react';
import { ChevronRight } from '@just_testing13/icons';
import { ChevronRight } from '@interlay/icons';

import { TextLinkProps } from '../TextLink';

Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/Breadcrumbs/Breadcrumbs.style.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import styled from 'styled-components';
import { theme } from '@just_testing13/theme';
import { theme } from '@interlay/theme';

import { Span } from '../Text';
import { TextLink } from '../TextLink';
Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/Breadcrumbs/Breadcrumbs.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { AriaBreadcrumbsProps, useBreadcrumbs } from '@react-aria/breadcrumbs';
import { Children, forwardRef, HTMLAttributes, isValidElement, ReactElement } from 'react';
import { useDOMRef } from '@just_testing13/hooks';
import { useDOMRef } from '@interlay/hooks';

import { BreadcrumbItem } from './BreadcrumbItem';
import { StyledList, StyledListItem, StyledNav } from './Breadcrumbs.style';
Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/CTA/CTA.style.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import styled from 'styled-components';
import { ArrowTopRightOnSquare } from '@just_testing13/icons';
import { ArrowTopRightOnSquare } from '@interlay/icons';

import { theme } from '../../../core/theme/src';
import { CTASizes, CTAVariants } from '../../../core/theme/src';
Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/CTA/CTA.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { useFocusRing } from '@react-aria/focus';
import { mergeProps } from '@react-aria/utils';
import { PressEvent } from '@react-types/shared';
import { ButtonHTMLAttributes, forwardRef } from 'react';
import { useDOMRef } from '@just_testing13/hooks';
import { useDOMRef } from '@interlay/hooks';

import { CTASizes } from '../../../core/theme/src';

Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/CTA/CTALink.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { useFocusRing } from '@react-aria/focus';
import { AriaLinkOptions, useLink } from '@react-aria/link';
import { mergeProps } from '@react-aria/utils';
import { AnchorHTMLAttributes, forwardRef } from 'react';
import { useDOMRef } from '@just_testing13/hooks';
import { useDOMRef } from '@interlay/hooks';

import { BaseCTA, BaseCTAProps } from './BaseCTA';
import { StyledIcon } from './CTA.style';
Expand Down
4 changes: 2 additions & 2 deletions packages/components/src/Card/Card.style.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import styled, { css } from 'styled-components';
import { theme } from '@just_testing13/theme';
import { BorderRadius, CardVariants, Spacing, Variants } from '@just_testing13/theme';
import { theme } from '@interlay/theme';
import { BorderRadius, CardVariants, Spacing, Variants } from '@interlay/theme';

import { Flex } from '../Flex';

Expand Down
4 changes: 2 additions & 2 deletions packages/components/src/Card/Card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import { useButton } from '@react-aria/button';
import { mergeProps } from '@react-aria/utils';
import { PressEvent } from '@react-types/shared';
import { forwardRef } from 'react';
import { BorderRadius, CardVariants, Spacing, Variants } from '@just_testing13/theme';
import { useDOMRef } from '@just_testing13/hooks';
import { BorderRadius, CardVariants, Spacing, Variants } from '@interlay/theme';
import { useDOMRef } from '@interlay/hooks';

import { FlexProps } from '../Flex';

Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/CoinIcon/CoinIcon.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Meta, StoryFn, StoryObj } from '@storybook/react';
import * as coins from '@just_testing13/coin-icons';

import * as coins from '../../../icons/coin/src';
import { Flex } from '../Flex';

import { CoinIcon, CoinIconProps } from './CoinIcon';
Expand Down
4 changes: 2 additions & 2 deletions packages/components/src/CoinIcon/CoinIcon.style.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import styled from 'styled-components';
import { Icon } from '@just_testing13/icon';
import { theme } from '@just_testing13/theme';
import { Icon } from '@interlay/icons';
import { theme } from '@interlay/theme';

const StyledFallbackIcon = styled(Icon)`
stroke: ${theme.icon.fallback.stroke};
Expand Down
5 changes: 3 additions & 2 deletions packages/components/src/CoinIcon/CoinIcon.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { forwardRef } from 'react';
import { IconProps } from '@just_testing13/icon';
import * as coins from '@just_testing13/coin-icons';
import { IconProps } from '@interlay/icons';

import * as coins from '../../../icons/coin/src';

import { FallbackIcon } from './FallbackIcon';
import { LPCoinIcon } from './LPCoinIcon';
Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/CoinIcon/LPCoinIcon.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { forwardRef, useCallback } from 'react';
import { Icon } from '@just_testing13/icon';
import { Icon } from '@interlay/icons';

import { CoinIconProps } from './CoinIcon';
import { FallbackIcon } from './FallbackIcon';
Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/CoinIcon/types.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ForwardRefExoticComponent, RefAttributes } from 'react';
import { IconProps } from '@just_testing13/icons';
import { IconProps } from '@interlay/icons';

export type CoinComponent = ForwardRefExoticComponent<IconProps & RefAttributes<SVGSVGElement>>;
4 changes: 2 additions & 2 deletions packages/components/src/Dialog/Dialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import { AriaDialogProps, useDialog } from '@react-aria/dialog';
import { mergeProps } from '@react-aria/utils';
import { PressEvent } from '@react-types/shared';
import { forwardRef, ReactNode } from 'react';
import { XMark } from '@just_testing13/icons';
import { useDOMRef } from '@just_testing13/hooks';
import { XMark } from '@interlay/icons';
import { useDOMRef } from '@interlay/hooks';

import { CTASizes, Sizes } from '../../../core/theme/src';

Expand Down
Loading

0 comments on commit ea64a94

Please sign in to comment.